<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ page import ="managesystem.Student" %>
<%@ page import ="controlsystem.AlertController" %>
<%@ page import ="controlsystem.Alert" %>
<%@ page import ="controlsystem.CourseDescription" %>
<%@ page import ="java.util.ArrayList" %>
<%@ page import="java.util.Iterator" %>
<link href="../styles/toolbar.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="../scripts/toolbar.js"></script>

<%
	Student currStud = (Student) session.getAttribute("currStud");
	String lname = currStud.getLname();
	String fname = currStud.getFname();
	boolean unFinished = (currStud.getUnfinishedActivity() != null) ? true : false;
%>

<div id="jqeasypanel">
	<ul class="panelbuttons">
    	<% if(!unFinished) { %>
        <li><a href="index.jsp?id=school"><img src="../images/toolbar/school_48.png" alt="Track an School activity" />School Activity</a></li>
         <li><a href="index.jsp?id=other"><img src="../images/toolbar/clipboard_48.png" alt="Track an Other activity" />Other Activity</a></li>
         <% } else { %>
         <li><a href="index.jsp?id=resume"><img src="../images/toolbar/resume.png" alt = "Resume a started activity" />Resume</a></li>
         <% } %>
        <li><a href="index.jsp?id=dashboard"><img src="../images/toolbar/diagram_48.png" alt="Show your statistics" />Dashboard</a></li>
        <li><a href="index.jsp?id=plot"><img src="../images/toolbar/diagram_48.png" alt="Show your statistics" />Plots</a></li>
        <li><a href="index.jsp?id=ucp"><img src="../images/toolbar/gear_48.png" alt="Change your account or settings" />Student Settings</a></li>
   		<li><a href="/logoutStudent"><img src="../images/toolbar/logout_48.png" alt="Sign out" />Sign out</a></li>
    </ul>
    <div id="copy">
    	<p>ControlPanel || <%=lname%> <%=fname%></p>	
    </div>
    <div>
    	<%
    		//ArrayList<Alert> alerts = AlertController.returnAlert(currStud);
    		//if(alerts.size()==0){
    			%> <!-- <div id="noalert">No alerts. </div>--><%
    		//}
    		//else{
    		//	//Iterator<Alert> iter = alerts.iterator();
    			//Iterator<Alert> iter = alerts.iterator();
    			//	%><!-- <div id="listalerts"></div>--><%
    		//}
  
    	%>
    </div>
    <div id="jqeasypaneloptions">
    	<p><label for="keepopen">Keep controlpanel open?</label> <input name="keepopen" id="keepopen" type="checkbox" value="" /></p>
    </div>
</div>
<div id="jqeasytrigger">
    <a href="#" class="open">ControlPanel</a>
    <a href="#" class="close">close</a>
</div>
<script type="text/javascript">
	    $('#jqeasypanel').jqEasyPanel({
			position: 'bottom'
		});
	
</script>